/**
 * 自动生成！请勿修改！
 */
import { command } from '../core/command';

class SleepMonitor {
    constructor(opt = {}) {
        const { device, to, ...opts } = opt;

        this.device = device || {};
        this.opts = opts || {};
        this._to = to;
    }

    get categoryCode() {
        return '010070009';
    }

    get categoryName() {
        return '\u7761\u7720\u76d1\u6d4b\u5e26';
    }

    getBedOff(params) {
        return command({
            method: 'getBedOff',
            methodId: 'p1vZRvmL',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    getHeartRate(params) {
        return command({
            method: 'getHeartRate',
            methodId: 'pUPQld1r',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    getRespiratoryRate(params) {
        return command({
            method: 'getRespiratoryRate',
            methodId: 'pZgunZ3d',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    getSleepStatus(params) {
        return command({
            method: 'getSleepStatus',
            methodId: 'pGoxILrZ',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    getSwitch(params) {
        return command({
            method: 'getSwitch',
            methodId: 'ppAXPreA',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }

    setSwitch(params) {
        return command({
            method: 'setSwitch',
            methodId: 'peH3fA7C',
            params,
            to: this.to?.[this.i] || this.to,
        });
    }
}

export default SleepMonitor;
